#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QMainWindow>
#include "plank.h"
#include "ball.h"
#include "brick.h"
#include <QHBoxLayout>
namespace Ui {
class MainWindow;
}

class MainWindow : public QMainWindow
{
    Q_OBJECT
public:
    explicit MainWindow(QWidget *parent = 0);
    ~MainWindow();
    Plank *pl;
    void mouseMoveEvent(QMouseEvent *e);
    ball * ba;
    void mousePressEvent(QMouseEvent *e);
    QTimer *tim;
    QTimer* timer;
    QList<brick *> bricks;
    QHBoxLayout * qhbb;
    bool guanka=false;
    int count = 0;
    QHBoxLayout qhb1;
    int Guan=1;
private:
    Ui::MainWindow *ui;
signals:
    void plankMove(double x);
    void success();
private slots:
    void on_actionChognqian_triggered();
    void on_action1_triggered();
    void on_action2_triggered();
    void on_action3_triggered();
    void on_action4_triggered();
    void on_action5_triggered();
    void on_action1_2_triggered();
    void on_action2_2_triggered();
    void remove();
    void end();
    void on_actionkais_triggered();
    void on_actionguanka_triggered();
    void on_actionjieshu_triggered();
    void on_actionguanka_2_triggered();
    void on_actionguanka_3_triggered();
    void on_actionguanka_4_triggered();
    void on_actionguanka_5_triggered();
    void on_action_guanka_triggered();
    void on_actionguanka_6_triggered();
};

#endif // MAINWINDOW_H
